/*
 * Copyright 2014 Cungmua, Inc.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *    http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package cungmua.vn.kiosk.model;

import android.os.Parcel;
import android.os.Parcelable;

/**
 * @author kelvin.nguyen
 * 
 */
public class SKU implements Parcelable {
	private int OrderId;
	private int SkuId;
	private String SkuName;
	private double Price;
	private int Quantity;
	private int ProductType;
	private int sku_status;
	private int sku_Quantity_Delivery;
	private int sku_why_change;

	/**
 * 
 */
	public SKU() {
		super();
		// TODO Auto-generated constructor stub
	}

	public SKU(Parcel in) {
		readFromParcel(in);
	}


	
	
	/**
	 * @param orderId
	 * @param skuId
	 * @param skuName
	 * @param price
	 * @param quantity
	 * @param productType
	 * @param sku_status
	 */
	public SKU(int orderId, int skuId, String skuName, double price,
			int quantity, int productType, int sku_status,int sku_Quantity_Delivery,int sku_why_change) {
		super();
		OrderId = orderId;
		SkuId = skuId;
		SkuName = skuName;
		Price = price;
		Quantity = quantity;
		ProductType = productType;
		this.sku_status = sku_status;
		this.sku_Quantity_Delivery=sku_Quantity_Delivery;
		this.sku_why_change=sku_why_change;
	}

	/**
	 * @return the orderId
	 */
	public int getOrderId() {
		return OrderId;
	}

	/**
	 * @param orderId the orderId to set
	 */
	public void setOrderId(int orderId) {
		OrderId = orderId;
	}

	/**
	 * @return the skuId
	 */
	public int getSkuId() {
		return SkuId;
	}

	/**
	 * @param skuId
	 *            the skuId to set
	 */
	public void setSkuId(int skuId) {
		SkuId = skuId;
	}

	/**
	 * @return the skuName
	 */
	public String getSkuName() {
		return SkuName;
	}

	/**
	 * @param skuName
	 *            the skuName to set
	 */
	public void setSkuName(String skuName) {
		SkuName = skuName;
	}

	/**
	 * @return the price
	 */
	public double getPrice() {
		return Price;
	}

	/**
	 * @param price
	 *            the price to set
	 */
	public void setPrice(double price) {
		Price = price;
	}

	/**
	 * @return the quantity
	 */
	public int getQuantity() {
		return Quantity;
	}

	/**
	 * @param quantity
	 *            the quantity to set
	 */
	public void setQuantity(int quantity) {
		Quantity = quantity;
	}

	/**
	 * @return the productType
	 */
	public int getProductType() {
		return ProductType;
	}

	/**
	 * @param productType
	 *            the productType to set
	 */
	public void setProductType(int productType) {
		ProductType = productType;
	}
	
	

	/**
	 * @return the sku_status
	 */
	public int getSku_status() {
		return sku_status;
	}

	/**
	 * @param sku_status the sku_status to set
	 */
	public void setSku_status(int sku_status) {
		this.sku_status = sku_status;
	}

	
	
	/**
	 * @return the sku_Quantity_Delivery
	 */
	public int getSku_Quantity_Delivery() {
		return sku_Quantity_Delivery;
	}

	/**
	 * @param sku_Quantity_Delivery the sku_Quantity_Delivery to set
	 */
	public void setSku_Quantity_Delivery(int sku_Quantity_Delivery) {
		this.sku_Quantity_Delivery = sku_Quantity_Delivery;
	}
	
	

	/**
	 * @return the sku_why_change
	 */
	public int getSku_why_change() {
		return sku_why_change;
	}

	/**
	 * @param sku_why_change the sku_why_change to set
	 */
	public void setSku_why_change(int sku_why_change) {
		this.sku_why_change = sku_why_change;
	}

	@Override
	public int describeContents() {
		// TODO Auto-generated method stub
		return 0;
	}

	/*
	 * (non-Javadoc)
	 * 
	 * @see android.os.Parcelable#writeToParcel(android.os.Parcel, int)
	 */
	@Override
	public void writeToParcel(Parcel dest, int flags) {
		dest.writeInt(SkuId);
		dest.writeString(SkuName);
		dest.writeDouble(Price);
		dest.writeInt(Quantity);
		dest.writeInt(ProductType);
		dest.writeInt(sku_Quantity_Delivery);
		dest.writeInt(sku_why_change);
	}

	/** The Constant CREATOR. */
	public static final Parcelable.Creator CREATOR = new Parcelable.Creator() {
		public SKU createFromParcel(Parcel in) {
			return new SKU(in);
		}

		public SKU[] newArray(int size) {
			return new SKU[size];
		}
	};

	/**
	 * Read from parcel.
	 * 
	 * @param in
	 *            the in
	 */
	private void readFromParcel(Parcel in) {
		SkuId = in.readInt();
		SkuName = in.readString();
		Price = in.readDouble();
		Quantity = in.readInt();
		ProductType = in.readInt();
		sku_Quantity_Delivery=in.readInt();
		sku_why_change=in.readInt();
	}

}
